const fs=require("fs")
const path=require("path")

let filePath=path.join(__dirname,"std-io.js")
let writePath=path.join(__dirname,"write-to.js")

let reader=fs.createReadStream(filePath);
let writer=fs.createWriteStream(writePath)
//pipe管道可以将流之间进行连接

reader.pipe(writer)